﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="eppIncluirHistAcoesJudiciais.aspx.cs" Inherits="Protegidos_Empresas__popup_eppIncluirHistAcoesJudiciais" %>

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajax" %>
<%@ Register TagPrefix="uc1" TagName="HeadTag"  Src="~/_includes/HeadTag.ascx" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <!-- Includes -->
    <uc1:HeadTag ID="HeadTag1" runat="server" />
</head>
<body>
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
        <telerik:RadProgressManager ID="RadProgressManager1" runat="server" />
        <script type="text/javascript">
            function CloseAndRebind(args)
            {
                GetRadWindow().Close();
                GetRadWindow().BrowserWindow.refreshGrid(args);
            }
    		
            function GetRadWindow()
            {
                var oWindow = null;
                if (window.radWindow) oWindow = window.radWindow; //Will work in Moz in all cases, including clasic dialog
                else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow;//IE (and Moz as well)
    				
                return oWindow;
            }

            function CancelEdit()
            {
                GetRadWindow().Close();		
            }
        </script>
        
        <table width="99%" align="right">
            <tr>
                <td>
                    <table>
                        <tr>
                            <td>
                            
                                <table width="100%" align="right" class="textoCZ_12">
                                    <tr id="trNumProcesso" runat="server">
                                        <td style="width: 160px"><span class="textoCZ_12">Processo nr.:</span></td>
                                        <td><asp:TextBox ID="txtNumProcesso" runat="server" Text=""></asp:TextBox></td>
                                    </tr>
                                    <tr id="trDataAbertura" runat="server">
                                        <td style="width: 160px"><span class="textoCZ_12">Abertura:</span></td>
                                        <td>
                                            <telerik:RadDatePicker ID="rdpDataAbertura" runat="server" Skin="Telerik" DateInput-Font-Names="Verdana">
                                                <DateInput DateFormat="dd/MM/yyyy"></DateInput>
                                            </telerik:RadDatePicker>
                                        </td>
                                    </tr>
                                    <tr id="trDataTermino" runat="server">
                                        <td style="width: 160px"><span class="textoCZ_12">Finalização:</span></td>
                                        <td>
                                            <telerik:RadDatePicker ID="rdpDataTermino" runat="server" Skin="Telerik" DateInput-Font-Names="Verdana">
                                                <DateInput DateFormat="dd/MM/yyyy"></DateInput>
                                            </telerik:RadDatePicker>
                                        </td>
                                    </tr>
                                    <tr id="trReclamante" runat="server">
                                        <td style="width: 160px"><span class="textoCZ_12">Reclamante:</span></td>
                                        <td>
                                            <asp:TextBox ID="txtReclamante" runat="server" Text=""></asp:TextBox>
                                        </td>
                                    </tr>
                                </table>
                                
                            </td>
                        </tr>
                        <tr runat="server" id="trTituloReclamante">
                            <td>
                                <div class="SuTituloVR">Novo Histórico</div>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <table width="100%" align="right" class="textoCZ_12">
                                    <tr id="trDataHistorico" runat="server">
                                        <td style="width: 160px"><span class="textoCZ_12">Data Histórico:</span></td>
                                        <td>
                                            <telerik:RadDatePicker ID="rdpDataHistorico" runat="server" DateInput-Font-Names="Verdana">
                                                <DateInput DateFormat="dd/MM/yyyy"></DateInput>
                                            </telerik:RadDatePicker>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <table width="100%" align="right" class="textoCZ_12">
                                    <tr runat="server" id="trNovoHistorico">
                                        <td><asp:TextBox ID="txtNovoHistorico" runat="server" Text="" TextMode="MultiLine" Width="350px" Height="100px"></asp:TextBox></td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <table width="100%" align="right" class="textoCZ_12">
                                    <tr id="trProcessoFinalizado" runat="server">
                                        <td style="width:160px"><span class="textoCZ_12">Processo Finalizado em:</span></td>
                                        <td>
                                            <telerik:RadDatePicker ID="rdpProcessoFinalizado" runat="server" Skin="Telerik" DateInput-Font-Names="Verdana">
                                                <DateInput DateFormat="dd/MM/yyyy"></DateInput>
                                            </telerik:RadDatePicker>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
            
            <tr runat="server" id="trSeleciona">
                <td>
                    <table>
                        <tr>
                            <td style="width:350px">
                            <br />
                                <telerik:RadUpload ID="RadUpload1" runat="server" 
                                    ControlObjectsVisibility="None"
                                    EnableFileInputSkinning="true" 
                                    InitialFileInputsCount="1" 
                                    Culture="Portuguese (Brazil)" Width="300px" Skin="Telerik" 
                                    MaxFileInputsCount="1"  
                                    AllowedFileExtensions=".pdf" >
                                    <Localization Add="Adicionar" Remove="Remover" Select="Procurar..." />
                                </telerik:RadUpload>
                                
                                <asp:CustomValidator ID="Customvalidator1" runat="server" Display="Dynamic" ClientValidationFunction="validateRadUpload1">
                                <span style="FONT-SIZE: 12px;">Formato inválido!</span>
                                </asp:CustomValidator>
                                <br>
                                <telerik:RadProgressArea id="progressArea1" runat="server" Skin="Default" >
                                    <Localization Uploaded="Enviado" CurrentFileName="Arquivo:" 
                                        ElapsedTime="Tempo:" EstimatedTime="Tempo estimado:" 
                                        TotalFiles="Total de arquivos:" TransferSpeed="Velocidade:" 
                                        UploadedFiles="Arquivos enviados:"></Localization>
                                </telerik:RadProgressArea>
                            </td>
                            <td>
                                <td><asp:Label ID="lblArquivo" runat="server" Text="" Width="30px"></asp:Label></td>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
            <tr runat="server" id="trResultado">
                <td>
                    <asp:label id="labelNoResults" runat="server" visible="True">Arquivo Enviado.</asp:label>
                    <asp:Repeater id="repeaterResults" runat="server" visible="False">
                        <HeaderTemplate>
                            Arquivo Enviado.<br />
                        </HeaderTemplate>
                        <ItemTemplate>
                            <span style="font-weight: normal; font-size: 12px; color: black;">
                                Arquivo:&nbsp;<%#DataBinder.Eval(Container.DataItem, "FileName").ToString()%><br />
                                Tamanho&nbsp;do&nbsp;Arquivo:&nbsp;<%#DataBinder.Eval(Container.DataItem, "ContentLength").ToString() + "&nbsp;bytes"%><br />
                                <br /><br />
                            </span>
                        </ItemTemplate>
                    </asp:Repeater>      
                </td>
            </tr>
            <tr>
                <td align="right">
                    <asp:Label ID="lblResultado" runat="server" EnableViewState="false"></asp:Label>
                </td>
            </tr>
            <tr>
                <td align="right">
                <br />
                    <asp:Button ID="btnGravar" runat="server" Text="Gravar" Width="110px" 
                         OnClick="btnGravar_Click" />&nbsp;&nbsp;
                    <asp:Button ID="btnFechar" runat="server" Text="Fechar" Width="110px" 
                         OnClick="btnFechar_Click" />
                </td>
            </tr>
        </table>
        
        <script type="text/javascript">
        function validateRadUpload1(source, arguments) {
            arguments.IsValid = getRadUpload('<%= RadUpload1.ClientID %>').validateExtensions();
        }
        </script>
    </form>
</body>
</html>
